<script type="text/javascript">
jQuery(function(){
    $( "#TicketAdvisoryPublish" ).datetimepicker({
        defaultDate: '',
        changeMonth: true,
        numberOfMonths: 1,
        dateFormat:'yy-mm-dd'
    });
});
</script>
<h1><?php echo $this->Html->image('bootstrap/posts.png')?>添加咨询</h1>
<div class="bloc">
	<div class="title">
		<?php echo $this->element('admin/bread')?>
	</div>
    <div class="content">
	<?php echo $this->Form->create('TicketAdvisory'); ?>
    <table style = 'width:100%'>
		<tr>
			<td colspan =2>
				<div class="input text required">
					<label>票品名称</label>
					<span>
						<?php
						echo $this->Form->input('ticket_id',array('type'=>'hidden','default'=>$ticket['Ticket']['id']));
						echo $this->Form->input('operator_id',array('type'=>'hidden','default'=>$Auth['id']));
						echo $this->Form->input('user_id',array('type'=>'hidden'));
						echo $this->Html->link($ticket['Ticket']['title'],
								array('admin'=>true,'plugin'=>false,'controller'=>'TicketAdvisories','action'=>'index',$ticket['Ticket']['id'])
						);
						?>
					</span>
				</div>
			</td>
		</tr>
		<tr>
			<td width = "50%">
				<?php echo $this->Form->input('question_ip',array('label'=>'咨询人IP')); ?>
			</td>
			<td width = "50%">
				<?php echo $this->Form->input('question_local',array('label'=>'咨询人所在地')); ?>
			</td>
		</tr>
		<tr>
			<td width = "50%">
				<?php echo $this->Form->input('publish',array('default'=>date('Y-m-d H:i:s'),'label'=>'回复日期','type'=>'text')); ?>
			</td>
			<td width = "50%">
				<?php echo $this->Form->input('ticket_show',array('label'=>'显示到票品','type'=>'checkbox')); ?>
			</td>
		</tr>
		<tr>
			<td colspan =2>
				<?php echo $this->Form->input('question',array('label'=>'咨询问题','style'=>'width:80%'));?>
			</td>
		</tr>
		<tr>
			<td colspan =2>
				<?php echo $this->Form->input('answer',array('label'=>'咨询回复','style'=>'width:80%'));?>
			</td>
		</tr>
		<tr>
			<td colspan =2>
				<?php echo $this->Form->input('enable',array('default'=>1,'type'=>'hidden'));  
						echo $this->Form->submit('Submit');
				?>
				
			</td>
		</tr>
	</table>
	<?php echo $this->Form->end(); ?>
	</div>
</div>
